package com.bbznb.mapper;

import com.bbznb.entity.MyOrder;
import com.bbznb.util.OrderQueryDTO;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface OrderMapper  {


@Insert("insert into my_order(username, title, price, create_time, update_time, order_status) values(#{username}, #{title}, #{price},now(),now(),1) ")
    void insert(MyOrder order);


    List<MyOrder> selectAll(@Param("username") String username, @Param("p") OrderQueryDTO orderQueryDTO);
}
